#define _CRT_SECURE_NO_WARNINGS
#include<stdio.h>
int main()
{
	int n, i,result;
	n = 0;
	result = 1;
	scanf("%d", &n);
	for (i = 1; i <= n; i++)
	{
		result *= i;
	}

	printf("%d", result);
	return 0;
}